package com.dayuanit.dy15.lesson28.demo5;

public class Test {

    public static void main(String[] args) {
        //买车票

        Station station = new Station(100);

        Runnable ticketRunnable = new Runnable() {
            @Override
            public void run() {
//                station.sellTikct();
                station.sellTikct2();
            }
        };

        //创建100个线程去买票
        for (int i=0; i<101; i++) {
            new Thread(ticketRunnable).start();
        }

    }
}
